import request from '@/utils/request'

export function listOffice(query) {
  return request({
    url: '/work/office/list',
    method: 'get',
    params: query
  })
}

export function getOffice(officeId) {
  return request({
    url: '/work/office/' + officeId,
    method: 'get'
  })
}

export function addOffice(data) {
  return request({
    url: '/work/office',
    method: 'post',
    data: data
  })
}

export function updateOffice(data) {
  return request({
    url: '/work/office',
    method: 'put',
    data: data
  })
}

export function delOffice(officeId) {
  return request({
    url: '/work/office/' + officeId,
    method: 'delete'
  })
}

// 选择框
export function optionSelect() {
  return request({
    url: '/work/office/optionselect',
    method: 'get'
  })
}
